
package com.ld.security.demo.config;

import com.ld.security.auth.shiro.configuration.AuthConfiguration;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry;


@Configuration

public class AuthMvcConfiguration extends AuthConfiguration {

    @Value("${upload.homePath}")
    private String homePath;

    @Value("${upload.vuePath}")
    private String vuePath;

    @Override
    public void addResourceHandlers(ResourceHandlerRegistry registry) {
        registry.addResourceHandler("/upload/**").addResourceLocations("file:"+homePath);
        registry.addResourceHandler("/vue/**").addResourceLocations("file:"+vuePath);
        registry.addResourceHandler("/html/**").addResourceLocations("classpath:/html/");
    }



}
